package auction_bid

import (
	"context"
	"hotgo/internal/service"

	"hotgo/api/api/auction_bid/v1"
)

func (c *ControllerV1) AuctionBid(ctx context.Context, req *v1.AuctionBidReq) (res *v1.AuctionBidRes, err error) {
	r, err := service.SysAuctionLog().Bid(ctx, &req.BidInp)
	if err != nil {
		return nil, err
	}
	res = new(v1.AuctionBidRes)
	res.BidModel = r
	return
}
